<!DOCTYPE html>
<html lang="en">
<head>
	<meta charset="UTF-8">
	<title>Document</title>
</head>
<body>
	
</body>
</html>
<script>
	//数组，存放大量数据的有序集合
	var arr = [1, "hello,world", false, {name:"小明",age:28}];
	//通过 数组名[下标] 的形式取出数组中的内容
	console.log(arr[0]);
	console.log(arr[1]);
    console.log(arr[2]);
    console.log(arr[3]);
    //console.log(arr[3].age,arr[3].name);

    //打印数组的长度（数组中元素的个数）
    console.log(arr.length);


    //通过循环遍历数组
    for (var i = 0; i < arr.length; i++) {
               console.log(arr[i]);
    }






</script>